#include<bits/stdc++.h>
#define int long long //ten year OI one empty
using namespace std;
const int MAXN=1e5;
int a[MAXN+5],c[MAXN+5],n,m,x[4];
bool d[20][MAXN+5];
signed main(){
    freopen("arena.in","r",stdin);
    freopen("arena.out","w",stdout);
    scanf("%lld%lld",&n,&m);
    for(int i=1;i<=n;i++) scanf("%lld",&a[i]);
    for(int i=1;i<=n;i++) scanf("%lld",&c[i]);
    int k=0,K=1;
    while(K<n) K*=2,k++;
    for(int i=1;i<=k;i++){
        for(int j=1;j<=(1<<(k-i));j++){
            int z;
            scanf("%lld",&z);
            d[i][j]=z&1;
        }
    }
    int T,x0,x1,x2,x3;
    scanf("%lld",&T);
    for(int p=1;p<=T;p++){
        for(int i=0;i<4;i++) scanf("%lld",&x[i]);

    }
    //I can't solve it!!!
    // yi si shi qu le suo you de li qi he shou duan
    return 0;
}
